package com.hdax.dm.api.item;

import com.hdax.dm.entity.item.Item;
import com.hdax.dm.entity.item.ItemComment;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@Api(tags = "商品评价模块")
public interface ItemCommentControllerApi {

    @PostMapping(path = "/item/getComments")
    @ApiOperation(value = "商品查询",notes = "商品详情评价查询")
    List<ItemComment> getComments(@RequestParam("id") Long id);

    @PostMapping(path = "/item/addComments")
    @ApiOperation(value = "商品评价添加",notes = "商品评价")
    boolean addComments(@RequestBody ItemComment itemComme);

}
